package com.km.team.phsystem.common.utils;

import java.io.File;
import java.time.LocalDate;

/**
 * Author: jiangjun
 * Date: 2019-01-19
 * Time: 15:06
 * Description:
 */
public class FileUtils {

    /**
     * 构造保存目录按年月份分隔
     * @return
     */
    public static String genSaveDir(){
        LocalDate now = LocalDate.now();
        int year = now.getYear();
        int month = now.getMonth().getValue() + 1;
        int day = now.getDayOfMonth();
        return year + File.separator + month + File.separator + day + File.separator;
    }
}
